@use 'sass:math';

@function rem($px) {
  @return math.div($px, 16) * 1rem;
}


.exam-container {
  min-height: 100vh;
  background: rgb(244, 243, 239);
  user-select: none;
  display: flex;
  flex-direction: column;
}

.real-content {
  width: 100%;
  padding: 5vh rem(20) 0;
  flex: 1 1 auto;
  min-height: rem(400);
  height: 62vh;
  box-sizing: border-box;
}

// @media screen and (max-height: 700px) {
//   .real-content {
//     padding-top: 2vh;
//     max-height: 60vh;
//   }

//   .real-content__question {
//     max-height: 30vh;
//   }

//   .real-content__info {
//     height: auto;
//     min-height: rem(120);
//     max-height: 25vh;
//   }
// }

// @media screen and (max-width: 1024px) {
//   .real-content {
//     height: 60vh;
//   }
// }

.u-font-18 {
  font-size: rem(18);
}


.real-content__title {
  width: rem(200);
  height: 8vh;
  line-height: 8vh;
  border: rem(2) solid rgb(171, 170, 166);
  position: relative;
}

.u-m-t-10 {
  margin-top: rem(10);
}

.real-content_title_top {
  height: rem(20);
  line-height: rem(20);
  top: rem(-10);
  left: 50%;
  transform: translate(-50%);
  font-size: rem(24);
  background: rgb(244, 243, 239);
  white-space: nowrap;
  position: absolute;
  color: #0075d0;
  font-weight: bold;
}

.w500 {
  // font-weight: 500;
  font-size: rem(26);
}

.real-content__info {
  width: rem(200);
  height: calc(41vh - rem(20) - rem(20));
  padding: rem(30) rem(20) rem(23);
  border: rem(2) solid rgb(171, 170, 166);
  font-size: rem(20);
  margin-top: rem(20);
  position: relative;
}

.headerImg {
  width: rem(70);
  height: rem(70);
  margin-left: rem(30);
  // margin-top: rem(19);
}

.u-m-t-20 {
  margin-top: rem(20);
}

.u-m-t-30 {
  margin-top: rem(30);
}

.u-m-t-5 {
  margin-top: rem(20);
}

.real-content__count {
  width: rem(200);
  height: 8vh;
  line-height: 8vh;
  border: rem(2) solid rgb(171, 170, 166);
  margin-top: rem(20);
  position: relative;
  font-size: rem(27);
}

.real-content__question {
  width: calc(100vw - rem(200) - rem(40) - rem(20));
  max-width: 100%;
  // max-height: 40vh; // 限制最大高度
  height: 57vh;
  border: rem(2) solid rgb(171, 170, 166);
  // border-right: none;
  padding: rem(20) 0 rem(20) rem(30);
  margin-left: rem(20);
  position: relative;
  display: flex;

  .examTips {
    height: rem(20);
    line-height: rem(20);
    top: rem(-10);
    font-size: rem(24);
    background: rgb(244, 243, 239);
    white-space: nowrap;
    position: absolute;
    color: #0075d0;
    left: rem(50);
    font-weight: bold;
    transform: none;
  }
}

.real-content__question-body {
  // height: 100%;
  font-size: rem(22);
}

.w-500 {
  font-weight: 500;
}

.exam-type-btn {
  background: #337ab7;
  padding: rem(2) rem(6);
  display: inline-block;
  border-radius: rem(6);
  color: #fff;
  margin-right: rem(10);
  font-size: rem(19);
}

.collect {
  margin-left: rem(20);
  color: rgb(255, 127, 0);
  background-color: white;
  border-radius: rem(5);
  padding: rem(5) rem(10);
  display: inline-flex;
  align-items: center;
  border: rem(1) solid rgb(141, 140, 141);
}

.img-20 {
  width: rem(20);
  height: rem(20);
}

.u-m-r-20 {
  margin-right: rem(20);
}

.real-content__answer {
  // padding: 5px 1.041667vw 0px;
  font-size: rem(26);
  display: flex;
  justify-content: space-between;
  // margin-top: rem(272);
}

.c-black {
  color: #303133;
}

.c-red {
  color: #e54e48;
}

.c-blue {
  color: #0075d0;
}

.selectAnswer {
  // float: left;
  // height: 8vh;
  width: rem(384);
  padding-right: 0;
  margin-right: 0;
  font-weight: bold;
}

// .options {
//   // float: right;
//   user-select: none;
// }

.float-l {
  float: left;
}

.u-font-15 {
  font-size: rem(15);
}

.u-font-30 {
  font-size: rem(30);
}

.real-content__answer-item {
  height: rem(60);
  width: rem(60);
  line-height: rem(60);
  margin-left: rem(18);
  border: rem(2) solid rgb(171, 170, 166);
  float: left;
  user-select: none;
  background-color: #fff;
  cursor: pointer;
}

.imagetable {
  border-collapse: collapse;
  text-align: center;
  font-size: rem(20);
  color: #333;
  margin-left: rem(20);

  .th:first-child .td {
    border-top: rem(2) solid #999999;
  }

  .td:first-child {
    border-left: rem(2) solid #999999;
  }

  .th .td {
    border-bottom: rem(2) solid #999999
  }

  .td {
    background: #fff;
    border-right: rem(2) solid #999999;
    height: rem(45.5);
    width: rem(74);
    // font-weight: bold;
    // width: 2.864583vw;
    box-sizing: border-box;
    line-height: rem(45.5);
    position: relative;
    z-index: 1;
    font-size: rem(14);
  }

  .bg-blue {
    background: #52adf2 !important;
  }
}

.real-content__reply {
  height: 8vh;
  margin: 0 rem(20) 0;
  padding: rem(10) rem(20);
  border-top: rem(4) solid rgb(62, 103, 162);
  border-bottom: rem(4) solid rgb(62, 103, 162);
  border-left: rem(2) solid rgb(171, 170, 166);
  border-right: rem(2) solid rgb(171, 170, 166);
}

.real-content__reply-btn {
  width: rem(100);
  height: rem(44);
  font-size: rem(18);
  font-weight: 600;
  margin-bottom: 0;
  text-align: center;
  vertical-align: middle;
  touch-action: manipulation;
  cursor: pointer;
  background-image: none;
  border: rem(1) solid transparent;
  white-space: nowrap;
  line-height: 1.5;
  user-select: none;
  padding: 0 rem(15);
  border-radius: rem(4);
  transition: color .2s linear, background-color .2s linear, border .2s linear, -webkit-box-shadow .2s linear;
  transition: color .2s linear, background-color .2s linear, border .2s linear, box-shadow .2s linear;
  transition: color .2s linear, background-color .2s linear, border .2s linear, box-shadow .2s linear, -webkit-box-shadow .2s linear;
  background-color: #fff;
  border-color: #dcdee2;
}

.boundary_button {
  color: #a4a4a4;
  font-weight: 400;
}

.default_button {
  color: #333;
  font-weight: 400;
}

.u-m-l-20 {
  margin-left: rem(20);
}

.q-img {
  // height: 23.5vh;
  height: 29.5vh;
  margin: 0 rem(20) 0;
  border: rem(2) solid rgb(171, 170, 166);
  border-top: none;
  padding: rem(19) 0;

  .el-image {
    height: 100%;
  }
}

.exam-confirm-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-content {
  box-shadow: 0 rem(2) rem(10) rgba(0, 0, 0, 0.1);
  width: rem(1010);
  background: #F4F0ED;
  border-radius: rem(20);
}

.operation-tips {
  height: rem(312);
  padding-left: rem(44);
  padding-top: rem(25);
  font-size: rem(24);
  font-weight: 500;
}

.u-m-b-26 {
  margin-bottom: rem(26);
}

.u-m-b-16 {
  margin-bottom: rem(16);
}

.button-group {
  display: flex;
  justify-content: center;
  align-items: center;
  height: rem(88);
  background: #006CD9;
  border-radius: 0 0 rem(20) rem(20);
}

.confirm-btn {
  cursor: pointer;
  width: rem(128);
  height: rem(52);
  background: #FFFFFF;
  border-radius: rem(4);
  border: rem(2) solid #CCCBCB;
  color: #333;
  font-size: rem(20);
}

.u-m-r-30 {
  margin-right: rem(30);
}

.selected {
  border: rem(4) solid red !important;
}

.selectedAnswer {
  border: rem(2) solid #0075d0 !important;
}

.wrong {
  color: #ff3332b3;
}

.modal-mask {
  position: fixed;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-wrapper {
  background: #7194e8;
  border-radius: rem(10);
  width: rem(1344);
  box-shadow: 0 rem(4) rem(24) rgba(0, 0, 0, 0.18);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: rem(12);
}

.modal-title {
  height: rem(88);
  background: #0768DD;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  border-radius: rem(20) rem(20) 0 0;
  font-size: rem(24);
  color: #fff;
}

.wrong-modal-title {
  color: #fff;
  font-size: 1.4em;
  font-weight: 500;
}

.wrong-modal-content {
  background: #fff;
  color: #333;
  padding: rem(16);
  font-size: rem(22);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.question-title {
  font-size: rem(22);
}

.question-options {
  margin-bottom: rem(16);
  line-height: 1.8;
  font-size: rem(25);
  font-weight: 500;
}

.question-img {
  display: block;
  margin: rem(16) auto 0 auto;
  max-width: rem(350);
  max-height: rem(150);
  border: rem(1) solid #eee;
  background: #fff;
  object-fit: contain;
}

.modal-bottom {
  margin-top: rem(27);
  padding: rem(16);
  background: #fff;
}

.modal-answer {
  color: #333;
  font-size: rem(22);
  margin-bottom: rem(19);
}

.wrong-select {
  margin-left: rem(35);
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: rem(10);
}

.modal-footer button {
  font-size: rem(27);
  padding: rem(6) rem(32);
  border: rem(1) solid #aaa;
  border-radius: rem(6);
  background: #fff;
  color: #333;
  font-weight: 400;
  cursor: pointer;
  transition: background 0.2s;
}

.modal-footer button:hover {
  background: #f0f0f0;
}

.countdown-tip {
  color: #666;
  font-size: rem(19);
  text-align: center;
  margin-top: rem(77);
}

// 考试结果弹框样式
.exam-result-modal {
  background: linear-gradient(180deg, #4A90E2 0%, #E8F4FD 100%);
  border-radius: rem(20);
  width: rem(600);
  max-width: 90vw;
  box-shadow: 0 rem(8) rem(32) rgba(0, 0, 0, 0.15);
  overflow: hidden;
}

.exam-result-content {
  padding: rem(40) rem(30);
  text-align: center;
}

.exam-result-header {
  margin-bottom: rem(30);
}

.exam-result-title {
  color: #fff;
  font-size: rem(32);
  font-weight: bold;
  margin: 0;
  text-shadow: 0 rem(2) rem(4) rgba(0, 0, 0, 0.1);
}

.exam-result-body {
  margin-bottom: rem(40);
}

.exam-result-subtitle {
  color: #344767;
  font-size: rem(24);
  margin-bottom: rem(20);
  font-weight: 500;
}

.exam-result-score {
  color: #344767;
  font-size: rem(28);
  font-weight: bold;
  margin-bottom: rem(20);
  text-shadow: 0 rem(2) rem(4) rgba(0, 0, 0, 0.1);
}

.exam-result-hint {
  color: #344767;
  font-size: rem(18);
  line-height: 1.5;
  opacity: 0.9;
}

.exam-result-footer {
  display: flex;
  justify-content: center;
  gap: rem(15);
  flex-wrap: wrap;
}

.exam-result-btn {
  padding: rem(12) rem(24);
  border: none;
  border-radius: rem(8);
  font-size: rem(18);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  min-width: rem(120);
  box-shadow: 0 rem(4) rem(12) rgba(0, 0, 0, 0.15);

  &:hover {
    transform: translateY(-2px);
    box-shadow: 0 rem(6) rem(16) rgba(0, 0, 0, 0.2);
  }

  &:active {
    transform: translateY(0);
  }
}

.retry-btn {
  background: linear-gradient(135deg, #4A90E2 0%, #357ABD 100%);
  color: #fff;

  &:hover {
    background: linear-gradient(135deg, #357ABD 0%, #2E6DA4 100%);
  }
}

.view-wrong-btn {
  background: linear-gradient(135deg, #FF6B35 0%, #F7931E 100%);
  color: #fff;

  &:hover {
    background: linear-gradient(135deg, #F7931E 0%, #E67E22 100%);
  }
}

.exit-btn {
  background: linear-gradient(135deg, #6C757D 0%, #495057 100%);
  color: #fff;

  &:hover {
    background: linear-gradient(135deg, #495057 0%, #343A40 100%);
  }
}
